<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html>
<head>
<!-- Copyright 1997 The Open Group, All Rights Reserved -->
<title>Environment Variables</title>
</head><body bgcolor=white>
<center>
<font size=2>
The Single UNIX &reg; Specification, Version 2<br>
Copyright &copy; 1997 The Open Group

</font></center><hr size=2 noshade><blockquote>
<center>
<h2><a name = "tag_002">&nbsp;</a>Environment Variables</h2>
</center>
<xref type="1" name="envvar"></xref>
<h3><a name = "tag_002_001">&nbsp;</a>Environment Variable Definition</h3>
Environment variables defined in this chapter
affect the operation of
multiple utilities,
functions and applications.
There are other environment variables that are of interest only
to specific utilities.
Environment variables that apply to a single utility only are
defined as part of the utility description.
See the
<b>ENVIRONMENT VARIABLES</b>
section of the utility descriptions in the <b>XCU</b> specification for information on environment
variable usage.
<p>
The value of an environment variable is a string
of characters.
For a C-language program,
an array of strings called the environment is made available
when a process begins.
The array is pointed to by the external variable
<i>environ</i>,
which is defined as:
<code>
<pre>
extern char **environ;
</code>
</pre>
<p>
These strings have the form
<i>name</i>=<i>value</i>;
<i>name</i>s
do not contain the character =.
For values to be portable across
XSI-conformant systems, the value must be composed of characters
from the portable character set (except NUL
and as indicated below).
There is no meaning associated with the order of strings in the environment.
If more than one string in a process' environment
has the same
<i>name</i>
the consequences are undefined.
<p>
Environment variable names used by the utilities in the <b>XCU</b> specification
consist solely of upper-case letters,
digits and the "_" (underscore) from the characters defined in
<xref href=portchar><a href="charset.html#tagt_1">
Portable Character Set
</a></xref>.
Other characters may be permitted by an implementation;
applications must tolerate the presence of such names.
Upper- and
lower-case letters retain their unique identities and are not folded together.
The name space of environment variable names containing lower-case
letters is reserved for applications.
Applications can define
any environment variables with names from this name space without
modifying the behaviour of the standard utilities.
<p>
The
<i>values</i>
that the environment variables may be assigned are not restricted except that
they are considered to end with a null byte and the total space used
to store the environment and the arguments to the process is limited to
{ARG_MAX}
bytes.
<p>
Other
pairs may be placed in the environment by, for example,
calling the
<i><a href="../xsh/putenv.html">putenv()</a></i>
function,
manipulating the
<i>environ</i>
variable, or by using
<i>envp</i>
arguments when creating a process; see
in the <b>XSH</b> specification.
<p>
It is unwise to conflict with certain variables that are
frequently exported by widely used command interpreters and
applications:
<pre>
<table  bordercolor=#000000 border=1 align=center><tr valign=top><td align=left>ARFLAGS
<td align=left>IFS
<td align=left>MAILPATH
<td align=left>PS1
<tr valign=top><td align=left>CC
<td align=left>LANG
<td align=left>MAILRC
<td align=left>PS2
<tr valign=top><td align=left>CDPATH
<td align=left>LC_ALL
<td align=left>MAKEFLAGS
<td align=left>PS3
<tr valign=top><td align=left>CFLAGS
<td align=left>LC_COLLATE
<td align=left>MAKESHELL
<td align=left>PS4
<tr valign=top><td align=left>CHARSET
<td align=left>LC_CTYPE
<td align=left>MANPATH
<td align=left>PWD
<tr valign=top><td align=left>COLUMNS
<td align=left>LC_MESSAGES
<td align=left>MBOX
<td align=left>RANDOM
<tr valign=top><td align=left>DATEMSK
<td align=left>LC_MONETARY
<td align=left>MORE
<td align=left>SECONDS
<tr valign=top><td align=left>DEAD
<td align=left>LC_NUMERIC
<td align=left>MSGVERB
<td align=left>SHELL
<tr valign=top><td align=left>EDITOR
<td align=left>LC_TIME
<td align=left>NLSPATH
<td align=left>TERM
<tr valign=top><td align=left>ENV
<td align=left>LDFLAGS
<td align=left>NPROC
<td align=left>TERMCAP
<tr valign=top><td align=left>EXINIT
<td align=left>LEX
<td align=left>OLDPWD
<td align=left>TERMINFO
<tr valign=top><td align=left>FC
<td align=left>LFLAGS
<td align=left>OPTARG
<td align=left>TMPDIR
<tr valign=top><td align=left>FCEDIT
<td align=left>LINENO
<td align=left>OPTERR
<td align=left>TZ
<tr valign=top><td align=left>FFLAGS
<td align=left>LINES
<td align=left>OPTIND
<td align=left>USER
<tr valign=top><td align=left>GET
<td align=left>LISTER
<td align=left>PAGER
<td align=left>VISUAL
<tr valign=top><td align=left>GFLAGS
<td align=left>LOGNAME
<td align=left>PATH
<td align=left>YACC
<tr valign=top><td align=left>HISTFILE
<td align=left>LPDEST
<td align=left>PPID
<td align=left>YFLAGS
<tr valign=top><td align=left>HISTORY
<td align=left>MAIL
<td align=left>PRINTER
<td align=left>&nbsp;
<tr valign=top><td align=left>HISTSIZE
<td align=left>MAILCHECK
<td align=left>PROCLANG
<td align=left>&nbsp;
<tr valign=top><td align=left>HOME
<td align=left>MAILER
<td align=left>PROJECTDIR
<td align=left>&nbsp;
</table>
</pre>
<p>
If the variables in the following
two sections are present in the environment
during the execution of an application or utility, they are given the meaning
described below.
Some are placed
into the environment by the implementation
at the time the user logs in;
all can be added or changed by the user
or any ancestor of the current process.
The implementation will add or change environment
variables named in this specification set only as
specified in this specification set.
If they are defined in the application's
environment, the utilities in the <b>XCU</b> specification and
the functions in the <b>XSH</b> specification assume they have the specified meaning.
Conforming applications
must not set these environment variables
to have meanings other than as described.
See
<i><a href="../xsh/getenv.html">getenv()</a></i>
and
the <b>XCU</b> specification, <a href="../xcu/chap2.html#tag_001_012"><b>Shell Execution Environment</b>&nbsp;</a>
for methods of accessing these variables.
<h3><a name = "tag_002_002">&nbsp;</a>Internationalisation Variables</h3>
<p>
This section describes environment variables that are relevant to the
operation of internationalised interfaces described in the
CAE Specification, <b>System Interfaces and Headers</b>, <b>Issue 5</b> and the CAE Specification, <b>Commands and Utilities, Issue 5</b>.
<p>
Users may use the following environment variables to announce specific
localisation requirements to applications.
Applications must retrieve this information using the
<i><a href="../xsh/setlocale.html">setlocale()</a></i>
function to initialise the correct behaviour of the internationalised
interfaces.
The descriptions of the internationalisation environment variables
describe the resulting behaviour only when the application locale
is initialised in this way.
<dl compact>

<dt><i>LANG</i><dd><index term="LANG, "></index>

This variable determines the locale category for native language,
local customs and coded character set in the absence of the
<i>LC_ALL</i>
and other
<i>LC_*</i> (<i>LC_COLLATE, LC_CTYPE, LC_MESSAGES, LC_MONETARY,
LC_NUMERIC, LC_TIME</i>)
environment variables.
This can be used by
applications to determine the language to use for error messages
and instructions, collating sequences, date formats, and so forth.

<dt><i>LC_ALL</i><dd><index term="LC_ALL, "></index>

This variable determines the values for all locale categories.
The value of the
<i>LC_ALL</i>
environment variable has precedence over any of
the other environment variables starting with
<i>LC_</i> (<i>LC_COLLATE, LC_CTYPE, LC_MESSAGES, LC_MONETARY,
LC_NUMERIC, LC_TIME</i>)
and the
<i>LANG</i>
environment variable.

<dt><i>LC_COLLATE</i><dd><index term="LC_COLLATE, "></index>

This variable determines the locale category for character collation.
It determines collation
information for regular expressions and sorting, including
equivalence classes and multi-character collating elements,
in various utilities and the
<i><a href="../xsh/strcoll.html">strcoll()</a></i>
and
<i><a href="../xsh/strxfrm.html">strxfrm()</a></i>
functions.
Additional semantics of this variable, if any, are implementation-dependent.

<dt><i>LC_CTYPE</i><dd><index term="LC_CTYPE, "></index>

This variable determines the
locale category for character handling functions,
such as
<i><a href="../xsh/tolower.html">tolower()</a></i>,
<i><a href="../xsh/toupper.html">toupper()</a></i>
and
<i><a href="../xsh/isalpha.html">isalpha()</a></i>.
This environment variable determines
the interpretation of sequences of bytes of text
data as characters (for example, single- as opposed to
multi-byte characters), the classification of
characters (for example, alpha, digit, graph) and the
behaviour of character classes.
Additional semantics of this variable, if any, are implementation-dependent.

<dt><i>LC_MESSAGES</i><dd><index term="LC_MESSAGES, "></index>

This variable determines the locale category for processing affirmative and
negative responses and the language and cultural conventions in which messages
should be written.

It also affects the behaviour of the
<i><a href="../xsh/catopen.html">catopen()</a></i>
function in determining the message catalogue.
Additional semantics of this variable, if any, are implementation-dependent.
The language and cultural conventions of diagnostic and
informative messages whose format is unspecified
by this specification set should be affected by the setting of
<i>LC_MESSAGES</i>.

<dt><i>LC_MONETARY</i><dd><index term="LC_MONETARY, "></index>

This variable determines the
locale category for monetary-related numeric formatting information.
Additional semantics of this variable, if any, are implementation-dependent.

<dt><i>LC_NUMERIC</i><dd><index term="LC_NUMERIC, "></index>

This variable determines the
locale category for numeric formatting (for example, thousands separator
and radix character) information
in various utilities as well as the formatted I/O operations in
<i><a href="../xsh/printf.html">printf()</a></i>
and
<i><a href="../xsh/scanf.html">scanf()</a></i>
and the string conversion functions in
<i><a href="../xsh/strtod.html">strtod()</a></i>.
Additional semantics of this variable, if any, are implementation-dependent.

<dt><i>LC_TIME</i><dd><index term="LC_TIME, "></index>

This variable determines the
locale category for date and time formatting information.
It affects the behaviour of the time functions in
<i><a href="../xsh/strftime.html">strftime()</a></i>.
Additional semantics of this variable, if any, are implementation-dependent.

<dt><i>NLSPATH</i><dd><index term="NLSPATH, "></index>

This variable contains a sequence of templates that the
<i><a href="../xsh/catopen.html">catopen()</a></i>
function uses when attempting to locate message catalogues.
Each template consists of
an optional prefix,
one or more substitution fields,
a filename and an optional suffix.

For example:
<code>
<pre>
NLSPATH="/system/nlslib/%N.cat"
</code>
</pre>

defines that
<i><a href="../xsh/catopen.html">catopen()</a></i>
should look for all message catalogues in the
directory
<b>/system/nlslib</b>,
where the catalogue name should be constructed from the
<i>name</i>
parameter passed to
<i><a href="../xsh/catopen.html">catopen()</a></i>
(<b>%N</b>),
with the suffix
<b>.cat</b>.

Substitution fields consist of a "%"
symbol, followed by a single-letter keyword.
The following keywords are currently defined:
<dl compact>

<dt>%N<dd>The value of the
<i>name</i>
parameter passed to
<i><a href="../xsh/catopen.html">catopen()</a></i>.

<dt>%L<dd>The value of
the LC_MESSAGES category.

<dt>%l<dd>The
<i>language</i>
element from
the LC_MESSAGES category.

<dt>%t<dd>The
<i>territory</i>
element from
the LC_MESSAGES category.

<dt>%c<dd>The
<i>codeset</i>
element from
the LC_MESSAGES category.

<dt>%%<dd>A single % character.

</dl>
<p>
An empty string is substituted if the specified value is not
currently defined.
The separators underscore (_) and period (.) are not included in
%t and %c substitutions.
<p>
Templates defined in
<i>NLSPATH</i>
are separated by colons (:).
A leading or two adjacent colons :: is equivalent to
specifying %N.
For example:
<code>
<pre>
NLSPATH=":%N.cat:/nlslib/%L/%N.cat"
</code>
</pre>
indicates to
<i><a href="../xsh/catopen.html">catopen()</a></i>
that it should look for the requested message catalogue in <i>name</i>,
<i>name</i><b>.cat</b> and <b>/nlslib/</b><i>category</i><b>/</b><i>name</i><b>.cat</b>, where
<i>category</i>
is the value of the LC_MESSAGES category of the current locale.
<p>
Users should not set the 
<i>NLSPATH</i> 
variable unless they have a
specific reason to override the default system path. Setting
<i>NLSPATH</i>
to override the default system path produces undefined
results in the standard utilities and in applications with
appropriate privileges.
<p>
</dl>
<p>
The environment variables
<i>LANG</i>,
<i>LC_ALL</i>,
<i>LC_COLLATE</i>,
<i>LC_CTYPE</i>,
<i>LC_MESSAGES</i>,
<i>LC_MONETARY</i>,
<i>LC_NUMERIC</i>,
<i>LC_TIME</i>,
<i>(LC_*)</i>,
and
<i>NLSPATH</i>
provide for the support of internationalised applications.
The standard utilities make use of these
environment variables as described in this section and the
individual
<b>ENVIRONMENT VARIABLES</b>
sections for the utilities.
If these variables specify locale categories
that are not based upon the same
underlying codeset, the results are unspecified.
<p>
The values of locale categories are determined by a precedence order;
the first condition met below determines the value:
<ol>
<p>
<li>
If the
<i>LC_ALL</i>
environment variable is defined and is
not null, the value of
<i>LC_ALL</i>
is used.
<p>
<li>
If the
<i>LC_*</i>
environment variable
( <i>LC_COLLATE, LC_CTYPE, LC_MESSAGES, LC_MONETARY, LC_NUMERIC, LC_TIME</i>)
is defined and is not null, the value of the
environment variable is used to initialise the
category that corresponds to the environment variable.
<p>
<li>
If the
<i>LANG</i>
environment variable is defined and is
not null, the value of the
<i>LANG</i>
environment variable is used.
<p>
<li>
If the
<i>LANG</i>
environment variable is not set or is set
to the empty string, the implementation-dependent
default locale is used.
<p>
</ol>
<p>
If the locale value is "C" or "POSIX",
the POSIX locale is used and the
standard utilities behave in accordance with the rules in
<xref href=posixloc><a href="locale.html#tag_005_002">
POSIX Locale
</a></xref>,
for the associated category.
<p>
If the locale value begins with a slash, it is interpreted as the
pathname of a file that was created in the output format used by the
<i><a href="../xcu/localedef.html">localedef</a></i>
utility; see
<b>OUTPUT FILES</b>
under
<i><a href="../xcu/localedef.html">localedef</a></i>.
Referencing such a
pathname will result in that locale being used for the indicated category.
<p>
If the locale value has the form:
<code>
<pre>
<i>language</i><b>[</b><i>_territory</i><b>][</b><i>.codeset</i><b>]
</b></code>
</pre>
it refers to an implementation-provided locale, where settings of
language, territory and codeset are implementation-dependent.
<p>
<i>LC_COLLATE</i>, 
<i>LC_CTYPE</i>, <i>LC_MESSAGES</i>, <i>LC_MONETARY</i>, <i>LC_NUMERIC</i>
and
<i>LC_TIME</i>
are defined to accept an additional
field &quot;@<i>modifier</i> &quot;,
which allows the user to select
a specific instance of localisation data within a
single category (for example, for selecting the dictionary as opposed to the
character ordering of data).
The syntax for these environment
variables is thus defined as:
<code>
<pre>
<b>[</b><i>language</i><b>[</b><i>_territory</i><b>][</b><i>.codeset</i><b>][</b>@<i>modifier</i><b>]]
</b></code>
</pre>
For example, if a user wanted to interact with the system in French,
but required to sort German text files,
<i>LANG</i>
and
<i>LC_COLLATE</i>
could be defined as:
<code>
<pre>
LANG=Fr_FR
LC_COLLATE=De_DE
</code>
</pre>
<p>
This could be extended to select dictionary collation (say) by use of
the @<i>modifier</i> field; for example:
<code>
<pre>
LC_COLLATE=De_DE@dict
</code>
</pre>
An implementation may support other formats.
<p>
If the locale value is not recognised by the implementation, the
behaviour is unspecified.
<p>
At run time, these values are bound to a program's locale by calling the
<i><a href="../xsh/setlocale.html">setlocale()</a></i>
function.
<p>
Additional criteria for determining a valid locale name are
implementation-dependent.
<h3><a name = "tag_002_003">&nbsp;</a>Other Environment Variables</h3>
<dl compact>

<dt><i>COLUMNS</i><dd><index term="COLUMNS, "></index>

A decimal integer &gt; 0 used to indicate
the user's preferred width
in column positions for the terminal screen or window.
(See
<xref href=colpos><a href="glossary.html#tag_004_000_057">
column position
</a></xref>.)
If this variable is unset or null,
the implementation determines the number of
columns, appropriate for the terminal or window,
in an unspecified manner.
When
<i>COLUMNS</i>
is set, any terminal-width information implied by
<i>TERM</i>
will be overridden.
Users and portable applications should not set
<i>COLUMNS</i>
unless they wish to override the system selection
and produce output unrelated to the terminal characteristics.

The default value for the number of column positions is unspecified
because historical implementations use different methods
to determine values corresponding to the
size of the screen in which the utility is run.
This size is typically known to the implementation
through the value of
<i>TERM</i>
or by more elaborate methods such as extensions to the
<i><a href="../xcu/stty.html">stty</a></i>
utility, or knowledge of how the user is dynamically resizing windows
on a bit-mapped display terminal.
Users should not need to set this variable in the
environment unless there is a specific reason to
override the implementation's default behaviour,
such as to display data in an area arbitrarily smaller
than the terminal or window.

<dt><i>DATEMSK</i><dd><index term="DATEMSK, "></index>

Indicates the pathname of the template file used by
<i><a href="../xsh/getdate.html">getdate()</a></i>.

<dt><i>HOME</i><dd><index term="HOME, "></index>
The system will initialise this variable
at the time of login to be
a pathname of the user's home directory.
See
<i><a href="../xsh/pwd.h.html">&lt;pwd.h&gt;</a></i>.

<dt><i>LINES</i><dd><index term="LINES, "></index>
A decimal integer &gt; 0 used to indicate
the user's preferred number of lines on
a page or the vertical screen or
window size in lines.
A line in this case is a vertical measure large enough
to hold the tallest character in the character set being displayed.
If this variable is unset or null,
the implementation determines the number of
lines, appropriate for the terminal or window (size,
terminal baud rate, and so forth),
in an unspecified manner.
When
<i>LINES</i>
is set, any terminal-height information implied by
<i>TERM</i>
will be overridden.
Users and portable applications should not set
<i>LINES</i>
unless they wish to override the system selection
and produce output unrelated to the terminal characteristics.

The default value for the number of lines is unspecified
because historical implementations use different methods
to determine values corresponding to the
size of the screen in which the utility is run.
This size is typically known to the implementation
through the value of
<i>TERM</i>
or by more elaborate methods such as extensions to the
<i><a href="../xcu/stty.html">stty</a></i>
utility, or knowledge of how the user is dynamically resizing windows
on a bit-mapped display terminal.
Users should not need to set this variable in the
environment unless there is a specific reason to
override the implementation's default behaviour,
such as to display data in an area arbitrarily smaller
than the terminal or window.

<dt><i>LOGNAME</i><dd><index term="LOGNAME, "></index>

The system will initialise this variable
at the time of login to be
the user's login name.
See
<i><a href="../xsh/pwd.h.html">&lt;pwd.h&gt;</a></i>.
For a value of
<i>LOGNAME</i>
to be portable across implementations
of the ISO&nbsp;POSIX-1 standard, the value should be composed of characters from the
portable filename character set.

<dt><i>MSGVERB</i><dd><index term="MSGVERB, "></index>

Describes which message components are to be used in writing messages by
<i><a href="../xsh/fmtmsg.html">fmtmsg()</a></i>.

<dt><i>PATH</i><dd><index term="PATH, "></index>
The sequence of path prefixes
that certain functions
and utilities
apply in searching for an executable file known only by a filename.
The prefixes are separated by a colon (:)
When a non-zero-length prefix is applied to this filename,
a slash is inserted between the prefix and the filename.
A zero-length prefix is a legacy feature
that indicates the current working directory.
It appears as two adjacent colons (::),
as an initial colon preceding the rest of the list, or as a trailing
colon following the rest of the list.
A portable application must
use an actual pathname (such as .)
to represent the current working directory in
<i>PATH</i>.
The list is searched from beginning to end,
applying the filename to each prefix,
until an executable file
with the specified name and appropriate execution permissions is found.
If the pathname being sought contains a slash, the search through
the path prefixes will not be performed.
If the pathname begins with a slash, the specified path is
resolved (see
<xref href=pathres><a href="glossary.html#tag_004_000_198">
pathname resolution
</a></xref>).
If
<i>PATH</i>
is unset or is set to null, the path search is implementation-dependent.

<dt><i>SHELL</i><dd><index term="SHELL, "></index>
A pathname of the user's preferred command language interpreter.
If this interpreter does not conform to the
XSI Shell Command Language in the <b>XCU</b> specification, <a href="../xcu/chap2.html"><b>Shell Command Language</b>&nbsp;</a>,
utilities may behave differently from those described in this specification set.

<dt><i>TMPDIR</i><dd><index term="TMPDIR, "></index>

A pathname of a directory made available for programs
that need a place to create temporary files.

<dt><i>TERM</i><dd><index term="TERM, "></index>
The terminal type for which output is to be prepared.
This
information is used by utilities and application programs wishing
to exploit special capabilities specific to a terminal.
The format and allowable values of this environment variable are unspecified.

<dt><i>TZ</i><dd><index term="TZ, "></index>
Timezone information.
The contents of the environment variable named
<i>TZ</i>
are used by the
<i><a href="../xsh/ctime.html">ctime()</a></i>,
<i><a href="../xsh/localtime.html">localtime()</a></i>,
<i><a href="../xsh/strftime.html">strftime()</a></i>
and
<i><a href="../xsh/mktime.html">mktime()</a></i>
functions, and by various utilities,
to override the default timezone.
The value of
<i>TZ</i>
has one of the two forms (spaces inserted
for clarity):
<code>
<pre>
:<i>characters
</i></code>
</pre>
or:
<code>
<pre>
<i>std offset dst offset</i>, <i>rule
</i></code>
</pre>
If
<i>TZ</i>
is of the first format (that is, if the first character
is a colon), the characters following the colon are
handled in an implementation-dependent manner.

The expanded format (for all
<i>TZ</i>s
whose value does not have
a colon as the first character) is as follows:
<code>
<pre>
<i>stdoffset</i><b>[</b><i>dst</i><b>[</b><i>offset</i><b>][</b>,<i>start</i><b>[</b>/<i>time</i><b>]</b>,<i>end</i><b>[</b>/<i>time</i><b>]]]
</b></code>
</pre>
Where:
<dl compact>

<dt><i>std</i>&nbsp;and&nbsp;<i>dst</i><dd><br>
Indicates no less than three, nor more than
{TZNAME_MAX},
bytes that are the designation for the standard
( <i>std</i> )
or the alternative
( <i>dst</i>
- such as Daylight Savings Time) timezone.
Only
<i>std</i>
is required; if
<i>dst</i>
is missing,
then the alternative time does not apply in this locale.
Upper- and lower-case letters are explicitly allowed.
Any graphic characters except a leading colon
(:)
or digits,
the comma
(,),
the minus
(-),
the plus
(+),
and the null character are permitted
to appear in these fields,
but their meaning is unspecified.

<dt><i>offset</i><dd>Indicates the value one must add to the local time to arrive at
Coordinated Universal Time.
The
<i>offset</i>
has the form:
<pre>
<dl compact><dt> <dd>
<i>hh</i><b>[</b>:<i>mm</i><b>[</b>:<i>ss</i><b>]</b>]
</dl>
</pre>
The minutes
(<i>mm</i>)
and seconds
(<i>ss</i>)
are optional.
The hour
(<i>hh</i>)
is required and may be a single digit.
The
<i>offset</i>
following
<i>std</i>
is required.
If no
<i>offset</i>
follows
<i>dst</i>,
the alternative time is assumed to be one hour ahead of standard time.
One or more digits may be used;
the value is always interpreted as a decimal number.
The hour is between zero and 24,
and the minutes (and seconds)  if present  between
zero and 59.
Use of values outside these ranges causes undefined behaviour.
If preceded by a -, the timezone is east of the Prime Meridian;
otherwise it is west (which may be indicated by an optional preceding +).
<p>
<dt><i>rule</i><dd>Indicates when to change to and back from the alternative time.
The
<i>rule</i>
has the form:
<code>
<pre>
<i>date</i><b>[</b>/<i>time</i><b>]</b>,<i>date</i><b>[</b>/<i>time</i><b>]
</b></code>
</pre>
where the first
<i>date</i>
describes when the change from standard to alternative time occurs
and the second
<i>date</i>
describes when the change back happens.
Each
<i>time</i>
field describes when, in current local time, the change to
the other time is made.
<p>
The format of
<i>date</i>
is one of the following:
<dl compact>

<dt>J<i>n</i><dd>The Julian day
<i>n</i>
(1 
<i>n</i>
 365).
Leap days are not counted.
That is, in all years  including leap years  February 28 is day
59 and March 1 is day 60.
It is impossible to refer explicitly to the occasional February&nbsp;29.

<dt><i>n</i><dd>The zero-based Julian day
(0 
<i>n</i>
 365).
Leap days are counted, and it is possible to refer to February&nbsp;29.

<dt>M<i>m</i>.<i>n</i>.<i>d</i><dd>
The
<i>d</i><sup><small>th</small></sup>
day (0 
<i>d</i>
 6) of week
<i>n</i>
of month
<i>m</i>
of the year
(1 
<i>n</i>
 5, 1 
<i>m</i>
 12, where week 5 means &quot;the last
<i>d</i>
day in month
<i>m</i>&quot;
which may occur in either the fourth or the fifth week).
Week 1 is the first week in which the
day occurs.
Day zero is Sunday.

</dl>
<p>
The
<i>time</i>
has the same format as
<i>offset</i>
except that no leading sign (- or +) is allowed.
The default, if
<i>time</i>
is not given, is 02:00:00.
<p>
</dl>
<p>
</dl>
</blockquote>
<hr size=2 noshade>
<center><font size=2>
UNIX &reg; is a registered Trademark of The Open Group.<br>
Copyright &copy; 1997 The Open Group
<br> [ <a href="../index.html">Main Index</a> | <a href="../xshix.html">XSH</a> | <a href="../xcuix.html">XCU</a> | <a href="../xbdix.html">XBD</a> | <a href="../cursesix.html">XCURSES</a> | <a href="../xnsix.html">XNS</a> ]

</font></center><hr size=2 noshade>
</body></html>
